<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>添加商品</title>
<link href="${base}/resource/admin/css/common.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="${base}/resource/admin/js/jquery.js"></script>
<script type="text/javascript" src="${base}/resource/admin/js/jquery.validate.js"></script>
<script type="text/javascript" src="${base}/resource/admin/editor/kindeditor.js"></script>
<script type="text/javascript" src="${base}/resource/admin/js/common.js"></script>
<script type="text/javascript" src="${base}/resource/admin/js/input.js"></script>
<script type="text/javascript">

$().ready(function() {

	var $inputForm = $("#inputForm");
	[@flash_message /]

    $("#complaintTemplate").browser({type:"file"});

});
</script>
</head>
<body>
	<div class="path">
		<a href="${base}/admin/common/index.do">首页</a> &raquo;添加商品
	</div>
	<form id="inputForm" action="save.do" method="post" class="required-form" onsubmit="return validateForm(this)">
[#--        <ul id="tab" class="tab">
            <li>
                <input type="button" value="基础信息" />
            </li>
            <li>
                <input type="button" value="商品介绍" />
            </li>
        </ul>--]
        <table class="input tabContent">
            <tr>
                <th>
                    <span class="requiredField">*</span>所属分类:
                </th>
                <td>
                    <select name="productCategory.id" class="text required">
                        <option value="0" disabled="disabled">空</option>
                         [#list productCategoryList as productCategory]
                           <option value="${productCategory.id}">${productCategory.name}</option>
                        [/#list]
                    </select>
                </td>
            </tr>

			<tr>
				<th>
					<span class="requiredField">*</span>sn
				</th>
				<td>
					<input type="text" name="sn" class="text required" maxlength="100" />
				</td>
			</tr>
			<tr>
				<th>
                    <span class="requiredField">*</span>名称
				</th>
                <td>
                    <span class="fieldSet">
					    <input type="text" name="name" class="text required" maxlength="64" />
					</span>
                </td>
			</tr>
            <tr>
                <th>
                    <span class="requiredField">*</span>全称
                </th>
                <td>
                    <span class="fieldSet">
						<input type="text" name="appKey" class="text required" maxlength="64" />
					</span>
                </td>
            </tr>
            <tr>
                <th>
                    <span class="requiredField">*</span>售价
                </th>
                <td>
                    <span class="fieldSet">
						<input type="text" name="price" class="text required" maxlength="4" />
					</span>
                </td>
            </tr>
            <tr>
                <th>
                    <span class="requiredField">*</span>市场价
                </th>
                <td>
                    <span class="fieldSet">
						<input type="text" name="marketPrice" class="text required" maxlength="4" />
					</span>
                </td>
            </tr>
            <tr>
                <th>
                    <span class="requiredField">*</span>单位
                </th>
                <td>
                    <span class="fieldSet">
						<input type="text" name="unit" class="text required" maxlength="4" />
					</span>
                </td>
            </tr>
            <tr>
                <th>
                    <span class="requiredField">*</span>库存
                </th>
                <td>
                    <span class="fieldSet">
						<input type="text" name="stock" class="text required" maxlength="64" />
					</span>
                </td>
            </tr>
            <tr>
                <th>
                    <span class="requiredField">*</span>是否上架:
                </th>
                <td>
                    <select name="isMarketable" class="required">
                        <option value="1">是</option>
                        <option value="0">否</option>
                    </select>
                </td>
            </tr>
            <tr>
                <th>
                    <span class="requiredField">*</span>是否置顶:
                </th>
                <td>
                    <select name="isTop" class="required">
                        <option value="1">是</option>
                        <option value="0">否</option>
                    </select>
                </td>
            </tr>
            <tr>
                <th>
                    <span class="requiredField">*</span>介绍:
                </th>
                <td>
                    <textarea id="editor" name="introduction" class="editor" style="width: 100%;"></textarea>
                </td>
            </tr>
            <tr>
                <th>
                    &nbsp;
                </th>
                <td>
                    <input type="submit" class="button" value="提交" />
                    <input type="button" class="button" value="返回" onclick="location.href='list.do'" />
                </td>
            </tr>
		</table>
    </form>
</body>
</html>